#!/bin/bash
#see also modes/en-ru.mode
if [ -z "$1" ]
  then
    echo 'usage: ./test.sh "<word_to_translate>"'
    exit
fi

echo $1 \
| lt-proc ../en-ru.automorf.bin \
| apertium-tagger -g ../en-ru.prob \
| apertium-pretransfer \
| apertium-transfer -n ../apertium-en-ru.en-ru.genitive.t1x ../en-ru.genitive.bin \
| apertium-transfer ../apertium-en-ru.en-ru.t1x ../en-ru.t1x.bin ../en-ru.autobil.bin \
| apertium-interchunk ../apertium-en-ru.en-ru.t2x ../en-ru.t2x.bin \
| apertium-postchunk ../apertium-en-ru.en-ru.t3x ../en-ru.t3x.bin \
| lt-proc -g ../en-ru.autogen.bin

